import 'form_utils.dart';

class TransactionTypeUtils {
  static String getTransactionType(String type) {
    switch (type) {
      case 'purchase_order':
        return 'PO';
      case 'bill':
        return 'Bill';
      case 'expense':
        return 'Expense';
      case 'quotation':
        return 'Quotation';
      case 'in':
      case 'cash_in':
        return 'Money-In';
      case 'out':
      case 'cash_out':
        return 'Money-Out';
      case 'invoice':
        return 'Invoice';
      case 'transfer_in':
        return 'Transfer In';
      case 'transfer_out':
        return 'Transfer Out';
      case 'credit_note':
        return 'Credit \nNote';
      case 'debit_note':
        return 'Debit \nNote';
    }
    return type;
  }

  static String getTransactionTypeStatus(String type) {
    switch (type) {
      case 'purchase_order':
        return ReimburseModel.purchaseOrder;
      case 'bill':
        return ReimburseModel.bill;
      case 'expense':
        return ReimburseModel.expense;
      case 'quotation':
        return ReimburseModel.quotation;
      case 'in':
      case 'cash_in':
        return ReimburseModel.cashIn;
      case 'out':
      case 'cash_out':
        return ReimburseModel.cashOut;
      case 'invoice':
        return ReimburseModel.invoice;
      case 'transfer':
        return ReimburseModel.transfer;
      case 'credit_note':
        return ReimburseModel.creditNote;
      case 'debit_note':
        return ReimburseModel.debitNote;
    }
    return type;
  }
}
